package miracle.joker.design.bridge;

public class BridgeDemo {

    public static void main(String[] args) {
        CarFactory carFactory = new CarFactory();
        AbstractCar sedanCar = carFactory.createCar("Sedan", new PetrolEngine());
        sedanCar.run();

        AbstractCar hatchbackCar = carFactory.createCar("Hatchback", new DieselEngine());
        hatchbackCar.run();
    }
}
